import request from "../common/request"

// 封装和车有关的接口

// 获取车辆列表
export function readCarList(parmas){
	return request({
		url: '/car',
		method: 'get',
		parmas: parmas
	})
}

// 获取车辆详情
export function readCar(id){
	return request({
		url: '/car/'+id,
		method: 'get',
	})
}

// 删除车辆
export function deleteCar(id){
	return request({
		url: '/car/'+id,
		method: 'delete',
	})
}

// 创建车辆
export function createCar(parmas){
	return request({
		url: '/car/create',
		method: 'get',
		parmas: parmas
	})
}
// 更新车辆
export function updateCar(id,parmas){
	return request({
		url: '/car/' + id,
		method: 'put',
		parmas: parmas
	})
}

//车辆轨迹
export function carPath(id,parmas){
	return request({
		url: '/action/properties/' + id,
		method: 'get',
		parmas: parmas
	})
}
